-- 天与暴君
local tianyubaojun = fk.CreateSkill {
    name = "mcdh_tianyubaojun",
    frequency = Skill.Compulsory,
}

tianyubaojun:addEffect(fk.GameStart,{
    can_trigger = function(self, event, target, player, data)
        return player:hasSkill(self)
    end,
    on_use = function(self, event, target, player, data)
        local room = player.room
        room:addPlayerEquipSlots(player, { Player.WeaponSlot })
        local weaponEmpty = #player:getAvailableEquipSlots(Card.SubtypeWeapon) - #player:getEquipments(Card.SubtypeWeapon)
        if weaponEmpty > 0 then
            local cards =  room:getCardsFromPileByRule(".|.|.|.|.|weapon",math.min(weaponEmpty,2))
            room:moveCardIntoEquip(player, cards, self.name, false)
        end
    end
})

tianyubaojun:addEffect('prohibit',{
    prohibit_use = function(self, player, card)
        return player:hasSkill(self) and card and card.type == Card.TypeTrick
    end,
})

return tianyubaojun